// 通用API响应类型
export interface ApiResponse<T = any> {
  success: boolean
  data: T
  message: string
  code?: number
}

// 分页响应类型
export interface PaginatedResponse<T> {
  items: T[]
  total: number
  page: number
  limit: number
  totalPages: number
}

// 通用查询参数
export interface BaseQuery {
  page?: number
  limit?: number
  keyword?: string
  sortBy?: string
  sortOrder?: 'asc' | 'desc'
}

// 用户状态
export interface UserState {
  isLoggedIn: boolean
  userInfo: any
  token: string | null
}

// 购物车状态
export interface CartState {
  items: any[]
  total: number
  selectedItems: any[]
}

// 路由元信息
export interface RouteMeta {
  title?: string
  requiresAuth?: boolean
  hideInMenu?: boolean
  icon?: string
}

// 菜单项
export interface MenuItem {
  id: string
  title: string
  path: string
  icon?: string
  children?: MenuItem[]
}

// 面包屑项
export interface BreadcrumbItem {
  title: string
  path?: string
}